load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")

go_library(
    name = "rowcontainer",
    srcs = [
        "datum_row_container.go",
        "disk_row_container.go",
        "hash_row_container.go",
        "kvstreamer_result_disk_buffer.go",
        "numbered_row_container.go",
        "row_container.go",
    ],
    importpath = "github.com/cockroachdb/cockroach/pkg/sql/rowcontainer",
    visibility = ["//visibility:public"],
    deps = [
        "//pkg/kv/kvclient/kvstreamer",
        "//pkg/kv/kvpb",
        "//pkg/kv/kvserver/diskmap",
        "//pkg/roachpb",
        "//pkg/sql/catalog/catenumpb",
        "//pkg/sql/catalog/colinfo",
        "//pkg/sql/memsize",
        "//pkg/sql/pgwire/pgcode",
        "//pkg/sql/pgwire/pgerror",
        "//pkg/sql/rowenc",
        "//pkg/sql/sem/eval",
        "//pkg/sql/sem/tree",
        "//pkg/sql/sqlerrors",
        "//pkg/sql/types",
        "//pkg/util",
        "//pkg/util/bufalloc",
        "//pkg/util/cancelchecker",
        "//pkg/util/encoding",
        "//pkg/util/errorutil/unimplemented",
        "//pkg/util/hlc",
        "//pkg/util/log",
        "//pkg/util/metamorphic",
        "//pkg/util/mon",
        "//pkg/util/ring",
        "//pkg/util/sort",
        "@com_github_cockroachdb_errors//:errors",
    ],
)

go_test(
    name = "rowcontainer_test",
    size = "small",
    srcs = [
        "datum_row_container_test.go",
        "disk_row_container_test.go",
        "hash_row_container_test.go",
        "kvstreamer_result_disk_buffer_test.go",
        "numbered_row_container_test.go",
        "row_container_test.go",
    ],
    embed = [":rowcontainer"],
    deps = [
        "//pkg/base",
        "//pkg/kv/kvclient/kvstreamer",
        "//pkg/kv/kvpb",
        "//pkg/kv/kvserver/diskmap",
        "//pkg/roachpb",
        "//pkg/settings/cluster",
        "//pkg/sql/catalog/colinfo",
        "//pkg/sql/pgwire/pgcode",
        "//pkg/sql/pgwire/pgerror",
        "//pkg/sql/randgen",
        "//pkg/sql/rowenc",
        "//pkg/sql/sem/eval",
        "//pkg/sql/sem/tree",
        "//pkg/sql/types",
        "//pkg/storage",
        "//pkg/util/encoding",
        "//pkg/util/hlc",
        "//pkg/util/leaktest",
        "//pkg/util/log",
        "//pkg/util/mon",
        "//pkg/util/randutil",
        "@com_github_cockroachdb_errors//:errors",
        "@com_github_stretchr_testify//require",
    ],
)
